package Thread;


import java.util.Scanner;

public class Demo24 {
    public static void main(String[] args) {
       Object locker=new Object();
       Thread t1=new Thread(()->{
         try{
             System.out.println("t1 wait 之前");
            synchronized(locker){
                locker.wait();
            }
             System.out.println("t1 wait 之后");
         }catch(InterruptedException e){
             throw new RuntimeException();
           }
       });
    }
}
